home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Aminet 4
/
Aminet 4 - November 1994.iso
/
aminet
/
comm
/
term
/
vltj5867.lha
/
VLT
/
rexx
/
Remote.vlt
< prev
next >
Wrap
Text File
|
1994-03-27
|
1KB
|
51 lines
/** Remote.vlt
*
* Send a command to a remote VLT
*
**/
/*
* Add libraries if necessary
*/
if show("l", "rexxarplib.library") = 0 then do
check = addlib('rexxsupport.library', 0, -30, 0)
check = addlib('rexxarplib.library', 0, -30, 0)
end
/*
* The following sequence determines both VLT's screen and port name
*/
vltport = address()
cols = ScreenCols(vltport)
if cols == -1 then vltscreen = ""
else vltscreen = vltport
str = ""
do i = 1
/*
* First ask for a command to be executed by the remote VLT
*/
str = request(50, 50, ,
"Enter a command for the remote to execute:",str,,"Cancel", vltscreen)
if str = "" then exit(0);
/*
* The initial escape sequence...
*/
string = '1b'x||"[?91h"
/*
* ...and the password (AMIGA in this case)...
*/
string = string ||"AMIGA~"
/*
* ...and the command...
*/
string = string ||str
/*
* ...and the final escape sequence, make up the full string.
*/
string = string ||'1b'x||"[?91l"
/*
* Send this string without further translation to the remote VLT.
*/
'send raw ['string']'
end